package com.freemalll.merchant.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.freemalll.merchant.domain.entity.MerMerchant;
import com.freemalll.merchant.service.MerMerchantService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.freemalll.merchant.mapper.MerMerchantMapper;

import java.util.List;

/**
 * 服务层实现。
 *
 * @author songshixiong
 * @since 2025-05-14
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class MerMerchantServiceImpl extends ServiceImpl<MerMerchantMapper, MerMerchant> implements MerMerchantService {

    @Override
    public boolean checkIfThereIsAMerchantPresent(int limitTheNumberOfDays, String licenseCode, List<String> authStatus, String merId) {
        return baseMapper.checkIfThereIsAMerchantPresent(limitTheNumberOfDays, licenseCode, authStatus, merId);
    }

    @Override
    public boolean checkReturnTime(String merId, int limitTheNumberOfDays, String authStatus) {
        return baseMapper.checkReturnTime(merId, limitTheNumberOfDays, authStatus);
    }

    @Override
    public boolean checkMerName(String merchantName, List<String> authStatus, String merId) {
        return baseMapper.checkMerchantName(merchantName, authStatus, merId);
    }

    @Override
    public boolean checkMerNameAndLimitDay(int limitTheNumberOfDays, String merchantName, List<String> list, String merId) {
        return baseMapper.checkMerchantNameAndLimitDay(limitTheNumberOfDays, merchantName, list, merId);
    }

    @Override
    public boolean checkMerchantLicenseCode(String licenseCode, List<String> authStatus, String merId) {
        return baseMapper.checkMerchantLicenseCode(licenseCode, authStatus, merId);
    }

    @Override
    public boolean checkMerShortName(String merchantShortName, List<String> authStatus, String merId) {
        return baseMapper.checkMerShortName(merchantShortName, authStatus, merId);
    }

    @Override
    public boolean checkMerShortNameAndLimitDay(int limitTheNumberOfDays, String merchantName, List<String> authStatus, String merId) {
        return baseMapper.checkMerShortNameAndLimitDay(limitTheNumberOfDays, merchantName, authStatus, merId);
    }
}
